package cn.yh.shop.product.model;

import java.sql.Timestamp;
/**
 * 
 * @Description:商品+价格实体类
 * @author:"李雨"
 * @time:2016年12月19日 上午10:59:33
 */
public class GoodsPrice implements java.io.Serializable {
	/**
	 * @Description: serialVersionUID : TODO
	 */
	private static final long serialVersionUID = 1L;
	private Integer id;//商品id
	private String name;//商品名称
	private Integer cateId;//商品种类id
	private Integer brandId;//商品品牌id
	private Integer attrId;//商品属性id
	private Double discount;//商品折扣，小数点后保留两位
	private Integer isFree;//商品是否包邮 1.包邮 2.不包邮
	private Integer displsy;//商品是否显示到首页 1.不显示(默认) 2.显示
	private Integer isIntegral;//商品是否可用积分;1:可用(最高可用积分为商品价格)2:不可用
	private Integer status;//商品状态;1:上架(默认) 2:下架
	private Integer repertory;//商品库存
	private String addPeopleName;//添加商品人
	private Timestamp addTime;//添加时间
	private String altPeopleName;//修改商品人
	private Timestamp altTime;//修改时间
	private Double price;//商品单包装价格
	private String imgPath;//显示商品图片路径
	private String description;//商品描述（关键字）

	public GoodsPrice(Goods goods, Double price, String imgPath) {
		super();
		this.id = goods.getId();
		this.name = goods.getName();
		this.cateId = goods.getCateId();
		this.brandId = goods.getBrandId();
		this.attrId = goods.getAttrId();
		this.discount = goods.getDiscount();
		this.isFree = goods.getIsFree();
		this.displsy = goods.getDisplsy();
		this.isIntegral = goods.getIsIntegral();
		this.status = goods.getStatus();
		this.repertory = goods.getRepertory();
		this.addPeopleName = goods.getAddPeopleName();
		this.addTime = goods.getAddTime();
		this.altPeopleName = goods.getAltPeopleName();
		this.altTime = goods.getAltTime();
		this.description = goods.getDescription();
		this.price = price;
		this.imgPath = imgPath;
	}
	
	/**
	 * 
	 * @Description:无参构造器
	 */
	public GoodsPrice() {
		super();
	}
	
	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getCateId() {
		return cateId;
	}

	public void setCateId(Integer cateId) {
		this.cateId = cateId;
	}

	public Integer getBrandId() {
		return brandId;
	}

	public void setBrandId(Integer brandId) {
		this.brandId = brandId;
	}

	public Integer getAttrId() {
		return attrId;
	}

	public void setAttrId(Integer attrId) {
		this.attrId = attrId;
	}

	public Double getDiscount() {
		return discount;
	}

	public void setDiscount(Double discount) {
		this.discount = discount;
	}

	public Integer getIsFree() {
		return isFree;
	}

	public void setIsFree(Integer isFree) {
		this.isFree = isFree;
	}

	public Integer getDisplsy() {
		return displsy;
	}

	public void setDisplsy(Integer displsy) {
		this.displsy = displsy;
	}

	public Integer getIsIntegral() {
		return isIntegral;
	}

	public void setIsIntegral(Integer isIntegral) {
		this.isIntegral = isIntegral;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public Integer getRepertory() {
		return repertory;
	}

	public void setRepertory(Integer repertory) {
		this.repertory = repertory;
	}

	public String getAddPeopleName() {
		return addPeopleName;
	}

	public void setAddPeopleName(String addPeopleName) {
		this.addPeopleName = addPeopleName;
	}

	public Timestamp getAddTime() {
		return addTime;
	}

	public void setAddTime(Timestamp addTime) {
		this.addTime = addTime;
	}

	public String getAltPeopleName() {
		return altPeopleName;
	}

	public void setAltPeopleName(String altPeopleName) {
		this.altPeopleName = altPeopleName;
	}

	public Timestamp getAltTime() {
		return altTime;
	}

	public void setAltTime(Timestamp altTime) {
		this.altTime = altTime;
	}
	public Double getPrice() {
		return price;
	}
	public void setPrice(Double price) {
		this.price = price;
	}

	public String getImgPath() {
		return imgPath;
	}

	public void setImgPath(String imgPath) {
		this.imgPath = imgPath;
	}
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
}